//
//  ShapeMaker.m
//  外观模式
//
//  Created by flannery on 2018/12/18.
//  Copyright © 2018年 flannery. All rights reserved.
//

#import "ShapeMaker.h"
#import "Shape.h"
@interface ShapeMaker()
@property (nonatomic, strong) id<Shape> circle;
@property (nonatomic, strong) id<Shape> rectangle;
@property (nonatomic, strong) id<Shape> square;
@end
@implementation ShapeMaker

- (instancetype)init
{
    self = [super init];
    if (self) {
        self.circle = Circle.new;
        self.rectangle = Rectangle.new;
        self.square = Square.new;
    }
    return self;
}

- (void)drawCircle{
    [self.circle draw];
}

- (void)drawRectangle{
    [self.rectangle draw];
}

- (void)drawSquare{
    [self.square draw];
}
@end
